﻿using System;
using System.Collections.Generic;
using System.Text;

namespace StockTrader.FrontEnd.DataContract
{
    public class HastcOrderUI
    {
        private string _accountNo;
        public string AccountNo
        {
            get { return _accountNo; }
            set { _accountNo = value; }
        }
        private string _orderSide;
        public string Side
        {
            get { return _orderSide; }
            set { _orderSide = value; }
        }
        private string _symbol;
        public string Symbol
        {
            get { return _symbol; }
            set { _symbol = value; }
        }
        private long _volume;
        public long Volume
        {
            get { return _volume; }
            set { _volume = value; }
        }
        private string _price;
        public string Price
        {
            get { return _price; }
            set { _price = value; }
        }
        private long _volumeMatched;
        public long MVolume
        {
            get { return _volumeMatched; }
            set { _volumeMatched = value; }
        }
        private decimal _valueMatched;
        public decimal MValue
        {
            get { return _valueMatched; }
            set { _valueMatched = value; }
        }
        private decimal lastPrice;
        public decimal LastPrice
        {
            get { return lastPrice; }
            set { lastPrice = value; }
        }
        private List<HastcMatchedOrderUI> _matchedDetail;
        public List<HastcMatchedOrderUI> MatchedDetail
        {
            get { return _matchedDetail; }
            set { _matchedDetail = value; }
        }
        private string _orderNumber;
        public string OrderNo
        {
            get { return _orderNumber; }
            set { _orderNumber = value; }
        }
        private string _orderTimestamp;
        public string Time
        {
            get { return _orderTimestamp; }
            set { _orderTimestamp = value; }
        }
        private string _orderStatus;
        public string Status
        {
            get { return _orderStatus; }
            set { _orderStatus = value; }
        }


        public HastcOrderUI()
        {

        }
        public HastcOrderUI(string ts, string ordernum, string accountno, string side, string symbol, long vol, string price, long mvol, decimal mprice,  List<HastcMatchedOrderUI> match)
        {
            this._orderTimestamp = ts;
            this._orderNumber = ordernum;
            this._accountNo = accountno;
            this._orderSide = side;
            this._symbol = symbol;
            this._volume = vol;
            this._price = price;
            this._volumeMatched = mvol;
            this._valueMatched = mprice;
            this._matchedDetail = match;
        }

    }

    public class HastcMatchedOrderUI
    {
        private string _timeStamp;
        public string TimeStamp
        {
            get { return _timeStamp; }
            set { _timeStamp = value; }
        }
        private long _volumeMatched;
        public long Volume
        {
            get { return _volumeMatched; }
            set { _volumeMatched = value; }
        }
        private decimal _priceMatched;
        public decimal Price
        {
            get { return _priceMatched; }
            set { _priceMatched = value; }
        }
        private string _orderNumber;
        public string OrderNumber
        {
            get { return _orderNumber; }
            set { _orderNumber = value; }
        }
        private string _confirmNumber;
        public string ConfirmNumber
        {
            get { return _confirmNumber; }
            set { _confirmNumber = value; }
        }

        private string _counterAccountNo;
        public string MAccount
        {
            get { return _counterAccountNo; }
            set { _counterAccountNo = value; }
        }


        public HastcMatchedOrderUI()
        {
        }
        public HastcMatchedOrderUI(string ts, string ordernum, string confirmnum, long mvol, decimal mprice, string counteracc)
        {
            this._timeStamp = ts;
            this._orderNumber = ordernum;
            this._confirmNumber = confirmnum;
            this._volumeMatched = mvol;
            this._priceMatched = mprice;
            this._counterAccountNo = counteracc;
        }
    }
}
